import java.util.Scanner;

public class Test1 {
    //1、使用二维数组存储班上五个学生三门功课的考试成绩，要求输出每一个学生的总分、平均分、最高分、最低分
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int score[][] = new int[3][5];
        int max = 0, min = 0, sum = 0, avg = 0;
        for (int i = 0; i <= score.length; i++) {
            System.out.println("请输入第" + (i + 1) + "门课：");

            for (int j = 0; j < score[i].length; j++) {
                System.out.print("请输入第" + (j + 1) + "名学员成绩:");
                int scores = in.nextInt();
                score[i][j] = scores;
                sum += score[i][j];
                min = score[0][0];
                if (score[i][j] > max) {
                    max = score[i][j];
                }
                if (score[i][j] < min) {
                    min = score[i][j];
                }
            }

            avg = sum / score[i].length;
            System.out.println("第" + (i + 1) + "门课同学的总分：" + sum + ";平均分：" + avg + ";最高分：" + max + ";最低分：" + min);
        }
    }
}
